// pages/movDetail/movDetail.js
const {movieDetail} = require("../../models/movie")
Page({
  data: {
    movie:""
  },
  onLoad: function (options) {
    var {id} = options
    movieDetail(id).then(res=>{
      var movie = res.data.details[0]
      movie.labels = movie.labels.join('·')
      
      this.setData({
        movie
      })
    })
  }
})